<?php

namespace App\Http\Controllers\Api;

use App\Http\Controllers\ApiResponse;
use App\Http\Controllers\Controller;
use App\Share;
use Illuminate\Http\Request;

class ShareController extends Controller
{
    use ApiResponse;
    public $uid;
    public function __construct()
    {
        $this->uid=auth('api')->id();
    }
    public function index(Request $request)
    {
        $list=Share::with('user')->where('share_uid',$this->uid)->paginate($request->get('size',10));
        return $this->data($list);
    }
}
